const pool = require('./db.js');

module.exports = {
    getUser: async function () {
        //     try{

        //   }.catch(err){
        //     console.log(err,"查询用户表报错");
        //   },
        try {
            const [rows] = await pool.query('select * from user');
            return rows;
        } catch (error) {
            console.log(error, "查询用户表报错");
        }
    }
}